import entryFactory from 'bpmn-js-properties-panel/lib/factory/EntryFactory';

import {
    is
} from 'bpmn-js/lib/util/ModelUtil';

export default function (translate, group, element) {
    if (is(element, 'bpmn:StartEvent')) { // 可以在这里做类型判断
        debugger
        console.log(1);
        group.entries.push(entryFactory.textField(translate, {
            id: 'title',
            description: '权限的标题',
            label: '标题',
            modelProperty: 'title'
        }));
        group.entries.push(entryFactory.checkbox(translate, {
            id: 'checkbox',
            description: '',
            label: translate('checkbox'),
            modelProperty: 'checkbox'
        }));
        group.entries.push(entryFactory.textBox(translate, {
            id: 'textBox',
            description: '',
            label: translate('textBox'),
            modelProperty: 'textBox'
        }));
        group.entries.push(entryFactory.selectBox(translate, {
            id: 'selectBox',
            description: '',
            label: translate('selectBox'),
            modelProperty: 'selectBox',
            selectOptions:[
                {name:'自定义选项一',value:1},
                {name:'自定义选项二',value:2},
                {name:'自定义选项一',value:3},
            ]
        }));
   
        // group.entries.push(entryFactory.comboBox(translate, {
        //     id: 'comboBox',
        //     description: '',
        //     label: translate('comboBox'),
        //     modelProperty: 'comboBox'
        // }));

        // group.entries.push(entryFactory.table(translate, {
        //     id: 'table',
        //     description: '',
        //     label: translate('table'),
        //     modelProperty: 'table'
        // }));

        // group.entries.push(entryFactory.label(translate, {
        //     id: 'label',
        //     description: '',
        //     label: translate('label'),
        //     modelProperty: 'label'
        // }));

        // group.entries.push(entryFactory.link(translate, {
        //     id: 'link',
        //     description: '',
        //     label: translate('link'),
        //     modelProperty: 'link'
        // }));

        // group.entries.push(entryFactory.autoSuggest(translate, {
        //     id: 'autoSuggest',
        //     description: '',
        //     label: translate('autoSuggest'),
        //     modelProperty: 'autoSuggest'
        // }));
        // group.entries.push(entryFactory.collapsible(translate, {
        //     id: 'collapsible',
        //     description: '',
        //     label: translate('collapsible'),
        //     modelProperty: 'collapsible'
        // }));
        // group.entries.push(entryFactory.toggleSwitch(translate, {
        //     id: 'toggleSwitch',
        //     description: '',
        //     label: translate('toggleSwitch'),
        //     modelProperty: 'toggleSwitch'
        // }));
    }
}


